import request from '@/untils/request'

export const taskAll = () => {
    return request({
        url: `/task/selectAll`,
        method: 'GET',
    })
}


export const selectTaskByTaskName = (taskName) => {
    return request({
        url: `/task/selectByTaskName?taskName=${taskName}`,
        method: 'GET'
    })
}

export const addTask = (data) => {
    return request({
        url: `/task/taskAdd`,
        method: 'POST',
        data
    })
}

export const selectCalssifyNumber = () => {
    return request({
        url: `/task/supervise`,
        method: 'GET',
    })
}

//展示所有任务
export const selectAllTask = () => {
    return request({
        url: `/task/selectAllTask`,
        method: 'GET'
    })
}

//展示所有即将预期的任务
export const selectUpcomingTask = () => {
    return request({
        url: `/task/selectUpcomingTask`,
        method: 'GET'
    })
}

//展示超期的函数任务
export const selectExceedTask = () => {
    return request({
        url: `/task/selectExceedTask`,
        method: 'GET'
    })
}

//展示获取echarts 不同任务分类不同人数
export const selectTaskEcharts = () => {
    return request({
        url: `/task/selectTaskEcharts`,
        method: 'GET'
    })
}